<!DOCTYPE html>
<meta charset="utf-8">
<p>Tests that promise rejection events are muted for cross origin non-CORS scripts</p>
<script>
if (window.testRunner) {
    testRunner.dumpAsText();
    testRunner.waitUntilDone();
}

addEventListener('unhandledrejection', function(e) {
    console.log('FAIL: received unhandledrejection event');
});

function finishTest() {
    setTimeout(function() {
        setTimeout(function() {
            if (window.testRunner) {
                testRunner.notifyDone();
            }
        }, 0);
    }, 0);
};
</script>
<script src='http://localhost:8000/security/resources/promise-access-control.php?allow=false' onload='finishTest()'></script>
